Skip to content

Conversation

@wking
Copy link
Member

@wking wking commented Nov 9, 2019

We want to be able to distinguish these conditions, which can be due to internal misconfiguration or external Cincinnati/network errors. The former can be fixed by cluster admins. The latter could go either way.

I dropped the len(upstream) guard from checkForUpdate because there's already an earlier guard in syncAvailableUpdates. The guard I'm removing is from db150e6 (#45). The covering guard is from the later 286641d (#55).

@openshift-ci-robot openshift-ci-robot added the bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. label Nov 9, 2019
@openshift-ci-robot
Copy link
Contributor

@wking: This pull request references Bugzilla bug 1685338, which is invalid:

  • expected the bug to target the "4.3.0" release, but it targets "4.4.0" instead
  • expected dependent Bugzilla bug 1746905 to be in one of the following states: VERIFIED, RELEASE_PENDING, CLOSED (ERRATA), but it is CLOSED (DUPLICATE) instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

Details

In response to this:

Bug 1685338: pkg/cvo: Reason granularity for RemoteFailed

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci-robot openshift-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Nov 9, 2019
wking added a commit to wking/cluster-version-operator that referenced this pull request Nov 12, 2019
We want to be able to distinguish these conditions, which can be due
to internal misconfiguration or external Cincinnati/network errors
[1].  The former can be fixed by cluster admins.  The latter could go
either way.

I dropped the len(upstream) guard from checkForUpdate because there's
already an earlier guard in syncAvailableUpdates.  The guard I'm
removing is from db150e6 (cvo: Perform status updates in a single
thread, 2018-11-03, openshift#45).  The covering guard is from the later
286641d (api: Update to objects from openshift/api, 2018-11-15, openshift#55).

Personally, I'd rather have GetUpdates return an *Error, so we could
dispense with the cast and unused Unknown-reason fallback.  But
Abhinav wanted the explicit cast in return for a more familiar error
type [2].

[1]: https://bugzilla.redhat.com/show_bug.cgi?id=1685338
[2]: openshift#268 (comment)
@wking wking force-pushed the get-updates-error-granularity branch from 363a762 to 8772ab1 Compare November 12, 2019 00:17
if err != nil {
return nil, configv1.ClusterOperatorStatusCondition{
Type: configv1.RetrievedUpdates, Status: configv1.ConditionFalse, Reason: "InvalidID",
Message: fmt.Sprintf("invalid cluster ID: %v", err),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: %v vs %s ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: %v vs %s ?

I dunno what the difference is for error values, but sure, fixed with bff5982 -> dca2686.

@abhinavdahiya
Copy link
Contributor

except #268 (comment)
LGTM

We want to be able to distinguish these conditions, which can be due
to internal misconfiguration or external Cincinnati/network errors
[1].  The former can be fixed by cluster admins.  The latter could go
either way.

I dropped the len(upstream) guard from checkForUpdate because there's
already an earlier guard in syncAvailableUpdates.  The guard I'm
removing is from db150e6 (cvo: Perform status updates in a single
thread, 2018-11-03, openshift#45).  The covering guard is from the later
286641d (api: Update to objects from openshift/api, 2018-11-15, openshift#55).

Personally, I'd rather have GetUpdates return an *Error, so we could
dispense with the cast and unused Unknown-reason fallback.  But
Abhinav wanted the explicit cast in return for a more familiar error
type [2].

[1]: https://bugzilla.redhat.com/show_bug.cgi?id=1685338
[2]: openshift#268 (comment)
Moving it up one level into calculateAvailableUpdatesStatus places it
right next to the existing len(upstream) check, so now both "is the
upstream URI valid?" checks are in the same place.
@wking wking force-pushed the get-updates-error-granularity branch from bff5982 to dca2686 Compare November 13, 2019 05:30
@wking
Copy link
Member Author

wking commented Nov 13, 2019

/bugzilla refresh

@openshift-ci-robot
Copy link
Contributor

@wking: This pull request references Bugzilla bug 1685338, which is invalid:

  • expected dependent Bugzilla bug 1746905 to be in one of the following states: VERIFIED, RELEASE_PENDING, CLOSED (ERRATA), but it is CLOSED (DUPLICATE) instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

Details

In response to this:

/bugzilla refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@abhinavdahiya
Copy link
Contributor

/bugzilla refresh

@openshift-ci-robot openshift-ci-robot added bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. and removed bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. labels Nov 13, 2019
@openshift-ci-robot
Copy link
Contributor

@abhinavdahiya: This pull request references Bugzilla bug 1685338, which is valid.

Details

In response to this:

/bugzilla refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@abhinavdahiya
Copy link
Contributor

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Nov 13, 2019
@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: abhinavdahiya, wking

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [abhinavdahiya,wking]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-robot openshift-merge-robot merged commit 8240a9b into openshift:master Nov 13, 2019
@openshift-ci-robot
Copy link
Contributor

@wking: All pull requests linked via external trackers have merged. Bugzilla bug 1685338 has been moved to the MODIFIED state.

Details

In response to this:

Bug 1685338: pkg/cvo: Reason granularity for RemoteFailed

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@wking wking deleted the get-updates-error-granularity branch November 13, 2019 22:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants